package com.example.administrator.myleb.Util;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.view.animation.AnimationUtils;
import android.widget.ImageView;

import com.example.administrator.myleb.R;

public class Animation extends AppCompatActivity {
    ImageView imageView;

    private static final String TAG = "Animation";
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_animation);
        imageView = (ImageView) findViewById(R.id.image);

    }
    public void onClick(View view){
        switch (view.getId()){
            case R.id.button2:
                android.view.animation.Animation animation = AnimationUtils.loadAnimation(this, R.anim.alpha);
                imageView.startAnimation(animation);
                break;
            case R.id.button3:
                android.view.animation.Animation animation01 = AnimationUtils.loadAnimation(this, R.anim.scale);
                imageView.startAnimation(animation01);
                break;
            
           

        }




    }
}
